home *** CD-ROM | disk | FTP | other *** search
Wrap
Text File | 1998-08-11 | 1.0 KB | 39 lines | [ TEXT/ScoM]
m-to-length rest-symbol length-lists symbol-list rest-symbol: symbol or nil This function maps a list or lists of note-lengths against a list of symbols. If the list of symbols is longer than the note-length list the symbol output is trimmed accordingly. If the lists of symbols is shorter than the note-length list the symbol output will repeats itself. (setq len1 '(-1/20 1/10 1/20 1/20 3/20 -1/20 -1/20)) (setq len2 '((1/8 -1/8 1/8 1/8) (-1/4) (3/32 1/32 -1/8) (-1/4))) (setq sym1 '(a b)) (setq sym2 '(a b c d e f g)) (setq sym3 '((a b) (c d) (e f))) (setq tuning '((2048 -1024) (0 2048 0 -2048))) (m-to-length '= len1 sym1) => (= a b a b = =) (m-to-length nil len1 sym1) => (a b a b) (m-to-length '= len1 sym2) => (= a b c d = =) (m-to-length nil len1 sym2) => (a b c d) (m-to-length '= len2 sym1) => ((a = b a) (=) (b a =)) (m-to-length nil len2 sym1) => ((a b a) nil (b a)) (m-to-length 0 len2 tuning) => ((2048 0 -1024 2048) (0) (2048 -1024 0) (0)) (m-to-length nil len2 sym2) => ((a b c) nil (d e)) (m-to-length nil len2 sym3) => ((a b a) nil (e f) nil)